<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <title>计算属性getter</title>
</head>

<body>
    <script type="text/javascript" src="build.js"></script>
</body>
<div id="app">
    <a>{{ message }}</a>
    <ul> 
        <li> {{ name }}</li>
        <li>  {{ b }} </li>
    </ul>
   <button v-on:click="show()">点击测试</button>

</div>
<script type="text/javascript">
new Ue({
    el: '#app',
    data: {
        name :"Ue",
        message: 'Hello!'
    },
    computed: {
        //this.name
        //  依赖的wathcer对象有三个
        //  => watcher
        //      name
        //      b.get
        //      b
        //  
        //  dep =>notify 触发3个订阅的watcher对象
        //      只会加入队列  wathcher=> dom
        //                    watcher=> b
        //      修改b.get
        //      watcher.lazy  => wathcer.dirty = true
        //
        b: function() {
            var a = this.name;
            var b = this.message
            return a +" " +b
        }
    },
    methods: {
        show: function() {
            this.name = "aaron"
            this.message = "测试点击"
        }
    }
})

</script>

</html>
